<template>
  <div>
    <el-table :data="tableData" style="width: 100%" border>
      <el-table-column
        label="产品名称"
        prop="name"
        min-width="100"
      ></el-table-column>
      <el-table-column
        label="规格型号"
        prop="specification"
        min-width="100"
      ></el-table-column>
      <el-table-column
        label="产品单价"
        prop="onePrice"
        width="150"
      ></el-table-column>
      <el-table-column
        label="产品单位"
        prop="unitName"
        width="150"
      ></el-table-column>
      <el-table-column
        label="产品数量"
        prop="num"
        width="150"
      ></el-table-column>
      <el-table-column
        label="产品总额"
        prop="price"
        width="150"
      ></el-table-column>
    </el-table>
    <div class="price">
      <p>清单总计：{{ form.price }}元</p>
      <!-- <p>清单总计：{{ form.price + form.discountMoney }}元</p> -->
      <!-- <p v-if="form.isDiscount == 1">
        优惠金额：{{ form.discountMoney ? form.discountMoney : 0 }}元
      </p>
      <p v-if="form.isDiscount == 1">优惠后金额：{{ form.price }}元</p> -->
    </div>
  </div>
</template>
<script>
export default {
  name: 'products',
  props: {
    tableData: {
      type: Array,
      required: true,
      default: () => {
        return []
      }
    },
    form: {
      type: Object,
      required: true,
      default: () => {
        return {}
      }
    }
  },
  data () {
    return {

    }
  },
  mounted () {

  },
  methods: {
  }
}
</script>
<style lang='scss' scoped>
.contractItem {
  :deep(.el-form-item__content) {
    align-items: center;
  }
}
.price {
  display: flex;
  margin-top: 15px;
  p {
    margin-right: 25px;
  }
}
</style>